def by_name(t):
	def compare(x):
		return x[0].lower()
	return list(sorted(t, key=compare))
	
def by_score(t):
	def compare(x):
		return x[1];
	return list(sorted(t, key=compare, reverse=True))
	
l = [('Bob', 75), ('Adam', 92), ('Bart', 66), ('Lisa', 88)]

print(by_name(l))
print(by_score(l))